package com.ruoyi.quality.domain.vo;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.format.DateTimeFormat;
import com.ruoyi.common.annotation.ExcelDictFormat;
import com.ruoyi.common.annotation.Translation;
import com.ruoyi.common.constant.TransConstant;
import com.ruoyi.common.convert.ExcelDictConvert;
import lombok.Data;

import java.util.Date;



/**
 * 质量问题视图对象 quality_physical_defect
 *
 * @author ruoyi
 * @date 2023-07-31
 */
@Data
@ExcelIgnoreUnannotated
public class QualityPhysicalDefectVo {

    private static final long serialVersionUID = 1L;

    /**
     * 编号
     */
    @ExcelProperty(value = "编号")
    private Long defectId;

    /**
     * 通报id
     */
    @ExcelProperty(value = "通报id")
    private Long reportId;

    /**
     * 编号
     */
    @ExcelProperty(value = "编号")
    private String reportNumber;

    /**
     * 件号
     */
    @ExcelProperty(value = "件号")
    private String partNumber;

    /**
     * 名称
     */
    @ExcelProperty(value = "名称")
    private String partName;

    /**
     * 名称其他
     */
    @ExcelProperty(value = "名称其他")
    private String newPartName;

    /**
     * 分类
     */
    @ExcelProperty(value = "分类")
    private String defectClassification;

    /**
     * 责任工号
     */
    @ExcelProperty(value = "责任工号")
    private String workersId;

    /**
     * 责任人
     */
    @ExcelProperty(value = "责任人")
    private String workersName;

    /**
     * 责任人
     */
    private String nickName;


    /**
     * 图片
     */
    @ExcelProperty(value = "图片")
    private String defectPicture;

    /**
     * 图片
     */
    @Translation(type = TransConstant.OSS_ID_TO_URL,mapper = "defectPicture")
    private String photo;

    /**
     * 罚款
     */
    @ExcelProperty(value = "罚款")
    private Integer defectFine;

    /**
     * 部门简称
     */
    @ExcelProperty(value = "部门简称", converter = ExcelDictConvert.class)
    @ExcelDictFormat(dictType = "dept_abbreviation")
    private String deptAbbreviation;

    /**
     * 部门全称
     */
    @ExcelProperty(value = "部门全称", converter = ExcelDictConvert.class)
    @ExcelDictFormat(dictType = "dept_fullname")
    private String deptFullName;

    /**
     * 问题类别
     */
    private String defectClass;

    /**
     * 日期
     */
    @DateTimeFormat("YYYY-MM-DD")
    @ExcelProperty(value = "日期")
    private Date defectDate;

    /**
     * 所属公司
     */
    @ExcelProperty(value = "所属公司", converter = ExcelDictConvert.class)
    @ExcelDictFormat(dictType = "sys_user_company")
    private String companyId;

    /**
     * 日期年
     */
    @DateTimeFormat("YYYY")
    @ExcelProperty(value = "日期年")
    private Date dateYear;

    /**
     * 合同号
     */
    @ExcelProperty(value = "合同号")
    private String contractNumber;

}
